def build(env) {
    println "inner params: ${env}"

    stage('build') {

        dir('console-website') {
//            sh 'npm --registry https://registry.npm.taobao.org install'
            sh 'npm --registry https://registry.npm.taobao.org install'
            sh "grunt build:${params.ENV} --force"
        }

        archiveArtifacts "console-website/zip/mdm_${params.ENV}_client.zip"
    }
}

return this